package com.example.server.service.admin;


import com.baomidou.mybatisplus.extension.service.IService;
import com.example.server.common.config.auth.TokenUser;
import com.example.server.common.constant.Result;
import com.example.server.entity.Customer;
import com.example.server.vo.StaffVO;

/**
 * (User)表服务接口
 *
 * @author china.fuyao@outlook.com
 * @since 2020-03-25 18:20:47
 */
public interface AdminCustomerService extends IService<Customer> {
    /**
     * 用户账号密码登录
     *
     * @param name
     * @param password
     * @return
     */
    Result login(String name, String password);

    /**
     * 用户登出
     *
     * @param tokenUser
     * @return
     */
    Result logout(TokenUser tokenUser);

    /**
     * 员工列表
     * @param page
     * @param limit
     * @param customerId
     * @return
     */
    Result staffList(Integer page, Integer limit,String customerName, Integer roleId, Integer customerId);

    /**
     * 新增员工
     * @param staffVO
     * @param customerId
     * @return
     */
    Result addStaff(StaffVO staffVO, Integer customerId);

    /**
     * 修改员工
     * @param staffVO
     * @param customerId
     * @return
     */
    Result updateStaff(StaffVO staffVO, Integer customerId);

    /**
     * 删除员工
     * @param customerIds
     * @param customerId
     * @return
     */
    Result delStaff(String customerIds, Integer customerId);

    /**
     * 启/禁用角色
     * @param customerIds
     * @param enable
     * @param customerId
     * @return
     */
    Result setEnable(String customerIds, Integer enable, Integer customerId);

    /**
     * 修改员工密码
     * @param oldpassword
     * @param newPwdone
     * @param newPwdTwo
     * @param customerId
     * @return
     */
    Result updateStaffPw(String oldpassword, String newPwdone, String newPwdTwo, Integer customerId);
}